/*! \file mem_profile.cpp
 *	\brief 
 *
 *	created:	2009/11/20
 *	created:	20:11:2009   18:26
 *	filename: 	o:\main\libs\mem\mem_profile.cpp
 *	file path:	o:\main\libs\mem
 *	file base:	mem_profile
 *	file ext:	cpp
 *	author:		Vitalii Trubchaninov
 *				venngraydog@gmail.com
 */
 
#include "mem/stdafx.h"
#include "mem/mem_profile.h"

#include "mem/impl/provider.h"

namespace tt{
namespace mem{

#if TT_MEM_ENABLED && TT_MEM_PROFILING

MEM_API void serialize( const char* file_name, bool append )
{
	impl::g_provider().serialize(file_name, append);
}

MEM_API void* root_section( const char* root_section_name )
{
	return impl::g_provider().root_section(root_section_name);
}

MEM_API void register_new( void* section, unsigned int size )
{
	impl::g_provider().register_new( reinterpret_cast<impl::BlockInfo*>(section), size );
}

MEM_API void register_delete( void* section, unsigned int size )
{
	impl::g_provider().register_delete( reinterpret_cast<impl::BlockInfo*>(section), size );
}

#endif //TT_MEM_ENABLED && TT_MEM_PROFILING

} //mem
} //namespace tt
